//
//  CLCollect+oper.m
//  chanlin
//
//  Created by Ryan on 14-12-20.
//  Copyright (c) 2014年 chanlin. All rights reserved.
//

#import "CLCollect+oper.h"
#import "CLList.h"
#import "ClEntityHead.h"

@implementation CLCollect (oper)



- (void)fillByList:(CLList *)list{
    self.title=list.title;
    self.cHeight=list.cHeight;
    self.itemId=list.itemId;
    self.link=list.link;
    self.slider1=list.slider1;
    self.slider2=list.slider2;
    self.slider3=list.slider3;
    self.style=list.style;
    self.sub=list.sub;
    self.thumnail=list.thumnail;
    self.audio=list.audio;
    self.audioTime=list.audioTime;
    
    
    
}


- (void)fillByDic:(NSDictionary *)dic{
    self.title=[dic sgrGetStringForKey:@"title"];
    self.itemId=[dic sgrGetStringForKey:@"id"];
    self.link=[dic sgrGetIntForKey:@"type"];
    self.thumnail=[dic sgrGetStringForKey:@"newspic"];
    self.style=CLList_style_doc;
    self.cHeight=78.f;
    if(_isStrNotNull(self.thumnail)){
        self.style=CLList_style_doc_img;
    }
    
}

@end
